﻿CREATE TABLE [dbo].[Claim]
(
[SubscriberIDKey] [int] NULL,
[ProviderIDKey] [int] NULL,
[SubscriberPrimaryIdentifier] [nvarchar] (80) NULL,
[PatientAccountNumber] [nvarchar] (38) NULL,
[TotalClaimChargeAmount] [money] NULL,
[FacilityCodeValue] [nvarchar] (38) NULL,
[FacilityCodeQualifier] [nvarchar] (2) NULL,
[ClaimFrequencyTypeCode] [nvarchar] (10) NULL,
[ProviderOrSupplierSignatureIndicator] [nvarchar] (2) NULL,
[MedicareAssignmentCode] [nvarchar] (1) NULL,
[BenefitsAssignmentCertificationIndicator] [nvarchar] (1) NULL,
[ReleaseOfInformationCode] [nvarchar] (1) NULL,
[ExplanationOfBenefitsIndicator] [nvarchar] (1) NULL,
[DelayReasonCode] [nvarchar] (2) NULL,
[DischargeDateTimeQualifier] [nvarchar] (3) NULL,
[DischargeDateTimePeriodFormatQualifier] [nvarchar] (3) NULL,
[DischargeHour] [nvarchar] (35) NULL,
[StatementDateTimeQualifier] [nvarchar] (3) NULL,
[StatementDateTimePeriodFormatQualifier] [nvarchar] (3) NULL,
[StatementFromOrToDate] [nvarchar] (35) NULL,
[AdmissionDateTimeQualifier] [nvarchar] (3) NULL,
[AdmissionDateTimePeriodFormatQualifier] [nvarchar] (3) NULL,
[AdmissionDateAndHour] [nvarchar] (35) NULL,
[AdmissionCode] [nvarchar] (1) NULL,
[AdmissionSourceCode] [nvarchar] (1) NULL,
[PatientStatusCode] [nvarchar] (2) NULL,
[ContractTypeCode] [nvarchar] (50) NULL,
[ContractAmount] [nvarchar] (50) NULL,
[ContractPercentage] [nvarchar] (50) NULL,
[ContractCode] [nvarchar] (50) NULL,
[ContractTermDiscountPercentage] [nvarchar] (50) NULL,
[ContractVersionIdentfier] [nvarchar] (50) NULL,
[ClaimFrequencyCode] [nvarchar] (50) NULL,
[PayerAmountQualifierCode] [nvarchar] (3) NULL,
[PayerEstimatedMonetaryAmount] [money] NULL,
[PatientAmountQualifierCode] [nvarchar] (3) NULL,
[PatientEstimatedMonetaryAmount] [money] NULL,
[PatientPaidAmountQualifierCode] [nvarchar] (3) NULL,
[PatientPaidMonetaryAmount] [money] NULL,
[CreditCardAmountQualifierCode] [nvarchar] (30) NULL,
[CreditOrDebitCardMaximumAmount] [nvarchar] (30) NULL,
[AdjustedRepricedClaimReferenceNumber] [nvarchar] (30) NULL,
[RepricedClaimReferenceNumber] [nvarchar] (30) NULL,
[ValueAddedNetworkTraceNumber] [nvarchar] (30) NULL,
[DocumentControlIdentifier] [nvarchar] (30) NULL,
[ClaimOriginalReferenceNumber] [nvarchar] (30) NULL,
[InvestigationalDeviceExemptionIdentifier] [nvarchar] (30) NULL,
[ServiceAuthorizationExceptionCode] [nvarchar] (30) NULL,
[PeerReviewAuthorizationNumber] [nvarchar] (30) NULL,
[PriorAuthorizationNumber] [nvarchar] (30) NULL,
[MedicalRecordNumber] [nvarchar] (30) NULL,
[DemonstrationProjectIdentifier] [nvarchar] (30) NULL,
[FixedFormatInformation] [nvarchar] (80) NULL,
[ClaimNoteReferenceCode] [nvarchar] (3) NULL,
[ClaimNoteText] [nvarchar] (80) NULL,
[BillingNoteReferenceCode] [nvarchar] (3) NULL,
[BillingNoteText] [nvarchar] (80) NULL,
[PrincipalAdmittingECode1] [nvarchar] (30) NULL,
[PrincipalAdmittingECode2] [nvarchar] (30) NULL,
[PrincipalAdmittingECode3] [nvarchar] (30) NULL,
[PrincipalAdmittingECode4] [nvarchar] (30) NULL,
[DRGCode] [nvarchar] (30) NULL,
[PrincipalProcedureCode] [nvarchar] (30) NULL,
[ClaimQuantityQualifier] [nvarchar] (2) NULL,
[ClaimDaysCount] [int] NULL,
[UnitOrBasisForMeasurementCode] [nvarchar] (2) NULL,
[PricingMethodology] [nvarchar] (2) NULL,
[RepricedAllowedAmount] [money] NULL,
[RepricedSavingAmount] [money] NULL,
[RepricingOrganizationIdentifier] [nvarchar] (2) NULL,
[RepricingPerDiemOrFlatRateAmount] [money] NULL,
[RepricedApprovedDRGCode] [nvarchar] (30) NULL,
[RepricedApprovedAmount] [money] NULL,
[RepricedApprovedRevenueCode] [nvarchar] (48) NULL,
[RepricedProductOrServiceIDQualifier] [nvarchar] (2) NULL,
[RepricedApprovedHCPCSCode] [nvarchar] (48) NULL,
[RepricedUnitOrBasisForMeasurementCode] [nvarchar] (2) NULL,
[RepricedApprovedServiceUnitCount] [int] NULL,
[RepricedRejectReasonCode] [nvarchar] (2) NULL,
[RepricedPolicyComplianceCode] [nvarchar] (2) NULL,
[RepricedExceptionCode] [nvarchar] (2) NULL,
[AttendingPhysicianLastName] [nvarchar] (35) NULL,
[AttendingPhysicianFirstName] [nvarchar] (25) NULL,
[AttendingPhysicianPrimaryIdentifier] [nvarchar] (80) NULL,
[AttendingPhysicianSecondaryIdentifier] [nvarchar] (80) NULL,
[AttendingPhysicianIdCodeQualifier] [nvarchar] (2) NULL,
[AttendingPhysicianSpecialtyCode] [nvarchar] (30) NULL,
[OperatingPhysicianLastName] [nvarchar] (35) NULL,
[OperatingPhysicianFirstName] [nvarchar] (25) NULL,
[OperatingPhysicianPrimaryIdentifier] [nvarchar] (80) NULL,
[OperatingPhysicianSecondaryIdentifier] [nvarchar] (80) NULL,
[OperatingPhysicianIdCodeQualifier] [nvarchar] (2) NULL,
[OtherPhysicianLastName] [nvarchar] (35) NULL,
[OtherPhysicianFirstName] [nvarchar] (25) NULL,
[OtherPhysicianPrimaryIdentifier] [nvarchar] (80) NULL,
[OtherPhysicianSecondaryIdentifier] [nvarchar] (80) NULL,
[OtherPhysicianIdCodeQualifier] [nvarchar] (2) NULL,
[ServiceFacilityEntityIdentifierCode] [nvarchar] (3) NULL,
[ServiceFacilityEntityTypeQualifier] [nvarchar] (1) NULL,
[ServiceFacilityLaboratoryOrFacilityName] [nvarchar] (35) NULL,
[ServiceFacilityIdentificationCodeQualifier] [nvarchar] (2) NULL,
[LaboratoryOrFacilityPrimaryIdentifier] [nvarchar] (2) NULL,
[LaboratoryOrFacilityAddressLine1] [nvarchar] (55) NULL,
[LaboratoryOrFacilityAddressLine2] [nvarchar] (55) NULL,
[LaboratoryOrFacilityCityName] [nvarchar] (30) NULL,
[LaboratoryOrFacilityStateOrProvinceCode] [nvarchar] (2) NULL,
[LaboratoryOrFacilityPostalZoneOrZIPCode] [nvarchar] (15) NULL,
[CountryCode] [nvarchar] (3) NULL,
[ServiceFacilitySecondaryReferenceIdentificationQualifier] [nvarchar] (3) NULL,
[LaboratoryOrFacilitySecondaryIdentifier] [nvarchar] (30) NULL,
[LastClaimStatusCode] [nvarchar] (2) NULL,
[PatientPrimaryIdentifier] [nvarchar] (80) NULL,
[IsPatient] [nvarchar] (10) NULL,
[TransactionSetControlNumber] [nvarchar] (9) NULL,
[SubscriberHierarchicalIDNumber] [nvarchar] (9) NULL,
[InterchangeControlNumber] [nvarchar] (9) NULL,
[GroupControlNumber] [nvarchar] (9) NULL,
[ClaimIDKey] [int] NOT NULL IDENTITY(1, 1),
[EDIMessageType] [nvarchar] (50) NULL,
[BTSMessageID] [nvarchar] (100) NULL,
[BTSInterchangeID] [nvarchar] (100) NULL
) ON [PRIMARY]


